import request from "@/utils/request.js";

const baseurl = window.addressUrl

//获取任务列表
export const getTaskList = params => {
  return request({
    url:`${baseurl}/address/task/list`,
    method: "get",
    params
  });
};

//获取列表
export const getAllList = params => {
  return request({
    url:`${baseurl}/address/getAllList`,
    method: "get",
    params
  });
};



//创建任务  
export const taskCreate = data => {
  return request({
    url:`${baseurl}/address/task/create`,
    method: "post",
    data
  });
};

//删除任务  
export const taskDelete = params => {
  return request({
    url:`${baseurl}/address/task/delete`,
    method: "get",
    params
  });
};

//一码多址匹配详情
export const getMatchingResult = params => {
  return request({
    url:`${baseurl}/address/manyAddress/getResult`,
    method: "get",
    params
  });
};

//获取任务统计  
export const getStatistics = data => {
  return request({
    url:`${baseurl}/address/task/statistics`,
    method: "post",
    data
  });
};


//统一地址管理
export const getCodeTaskHandelData = params => {
  return request({
    url:`${baseurl}/address/task/getResult`,
    method: "get",
    params
  });
};

//匹配通过接口
export const editAIRes = data => {
  return request({
    url:`${baseurl}/address/manyAddress/editAI`,
    method: "post",
    data
  });
};

//替换分词结果
export const replaceWord = data => {
  return request({
    url:`${baseurl}/address/all/edit`,
    method: "post",
    data
  });
};
